<?php
require_once("connect.php");
$user = $_POST['user'];
if(!isset($user)) die;
$pass = md5($_POST['pass']);
$que = mysqli_query($db,"select * from user where uname='$user' and pass='$pass'");
$userObj = mysqli_fetch_assoc($que);
if(mysqli_num_rows($que) > 0){
	echo "success---".$userObj["uname"]."---".$userObj["no"];
}else{
	echo "failed";
}
?>